Processing math: 100%

solve_triangular_system Interface

public interface solve_triangular_system

Module Procedures

private module subroutine solve_tri_mtx(lside, upper, trans, nounit, alpha, a, b, err)

Solves a triangular system of equations of the form op(A)X=αB or Xop(A)=αB where A is a triangular matrix (either upper or lower) for the unknown X.

Arguments

Type IntentOptional Attributes Name
logical, intent(in) :: lside

Set to true to solve op(A)X=αB; else, set to false to solve Xop(A)=αB.

logical, intent(in) :: upper

Set to true if A is upper triangular; else, set to false if A is lower triangular.

logical, intent(in) :: trans

Set to true if op(A)=AT; else, set to false if op(A)=A.

logical, intent(in) :: nounit

Set to true if A is unit-triangular (ones on the diagonal); else, false if A is not unit-triangular.

real(kind=real64), intent(in) :: alpha

The scalar multiplier α.

real(kind=real64), intent(in), dimension(:,:) :: a

If lside is true, the M-by-M triangular matrix A; else, A is N-by-N if lside is false.

real(kind=real64), intent(inout), dimension(:,:) :: b

On input, the M-by-N matrix B. On output, the M-by-N solution matrix X.

class(errors), intent(inout), optional, target :: err

The error object to be updated.

private subroutine solve_tri_mtx_cmplx(lside, upper, trans, nounit, alpha, a, b, err)

Solves a triangular system of equations of the form op(A)X=αB or Xop(A)=αB where A is a triangular matrix (either upper or lower) for the unknown X.

Arguments

Type IntentOptional Attributes Name
logical, intent(in) :: lside

Set to true to solve op(A)X=αB; else, set to false to solve Xop(A)=αB.

logical, intent(in) :: upper

Set to true if A is upper triangular; else, set to false if A is lower triangular.

logical, intent(in) :: trans

Set to true if op(A)=AH; else, set to false if op(A)=A.

logical, intent(in) :: nounit

Set to true if A is unit-triangular (ones on the diagonal); else, false if A is not unit-triangular.

complex(kind=real64), intent(in) :: alpha

The scalar multiplier α.

complex(kind=real64), intent(in), dimension(:,:) :: a

If lside is true, the M-by-M triangular matrix A; else, A is N-by-N if lside is false.

complex(kind=real64), intent(inout), dimension(:,:) :: b

On input, the M-by-N matrix B. On output, the M-by-N solution matrix X.

class(errors), intent(inout), optional, target :: err

The error object to be updated.

private subroutine solve_tri_vec(upper, trans, nounit, a, x, err)

Solves the triangular system op(A)x=b where A is a triangular matrix.

Arguments

Type IntentOptional Attributes Name
logical, intent(in) :: upper

Set to true if A is upper triangular; else, set to false if A is lower triangular.

logical, intent(in) :: trans

Set to true if op(A)=AT; else, set to false if op(A)=A.

logical, intent(in) :: nounit

Set to true if A is unit-triangular (ones on the diagonal); else, false if A is not unit-triangular.

real(kind=real64), intent(in), dimension(:,:) :: a

The N-by-N triangular matrix A.

real(kind=real64), intent(inout), dimension(:) :: x

On input, the N-element vector b. On output, the N-element solution vector x.

class(errors), intent(inout), optional, target :: err

The error object to be updated.

private subroutine solve_tri_vec_cmplx(upper, trans, nounit, a, x, err)

Solves the triangular system op(A)x=b where A is a triangular matrix.

Arguments

Type IntentOptional Attributes Name
logical, intent(in) :: upper

Set to true if A is upper triangular; else, set to false if A is lower triangular.

logical, intent(in) :: trans

Set to true if op(A)=AT; else, set to false if op(A)=A.

logical, intent(in) :: nounit

Set to true if A is unit-triangular (ones on the diagonal); else, false if A is not unit-triangular.

complex(kind=real64), intent(in), dimension(:,:) :: a

The N-by-N triangular matrix A.

complex(kind=real64), intent(inout), dimension(:) :: x

On input, the N-element vector b. On output, the N-element solution vector x.

class(errors), intent(inout), optional, target :: err

The error object to be updated.